﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Corvus
{
    public interface IRepository<T>
        where T : class
    {

        IEnumerable<T> Query { get; }
        IEnumerable<T> Find(Func<T, bool> where);
        [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1716:IdentifiersShouldNotMatchKeywords", MessageId = "Single")]
        T Single(Func<T, bool> where);
        T First(Func<T, bool> where);

        void Delete(T entity);
        void Add(T entity);
        void SaveChanges();
    }
}
